import { singleton } from "tsyringe";
import type { CommonClassName } from "widget-operation";


@singleton()
export class CoreGlobal {
    origin: any = global;
    /*****
    com.stardust.autojs.runtime.ScriptRuntime@e8516a4
    *****/
    get runtime() {
        return this.origin.runtime
    }
    /*****
    org.autojs.autojs.App@9cdd34e
    *****/
    get context() {
        return this.origin.context
    }
    //__engine__ error Invalid JavaScript value of type com.stardust.autojs.engine.LoopBasedJavaScriptEngine ([remote]demo.js#2)
    /*****
    
    function Require(id, parent) {
        var normalizePath = normalizeName(id);
        if (builtInModules.indexOf(normalizePath) >= 0 && !files.exists(normalizePath)) {
            return NativeRequire.require(normalizePath);
        }
        if (id.startsWith("http://") || id.startsWith("https://")) {
            return NativeRequire.require(id);
        }
        var core;
        var native_;
        var file = Require.resolve(id, parent);
        if (!file) {
            if (typeof NativeRequire.require === "function") {
                if (Require.debug) {
                    System.out.println(["Cannot resolve", id, "defaulting to native"].join(" "));
                }
                native_ = NativeRequire.require(id);
                if (native_) {
                    return native_;
                }
            }
            System.err.println("Cannot find module " + id);
            throw new ModuleError("Cannot find module " + id, "MODULE_NOT_FOUND");
        }
        if (file.core) {
            file = file.path;
            core = true;
        }
        if (Require.cache[file]) {
            return Require.cache[file];
        } else {
            if (file.endsWith(".js")) {
                return Module._load(file, parent, core);
            } else {
                if (file.endsWith(".json")) {
                    return loadJSON(file);
                }
            }
        }
    }
    
    *****/
    require(id: string) {
        return this.origin.require(id)
    }
    /*****
    
    function (obj, functions) {
        var len = functions.length;
        for (var i = 0; i < len; i++) {
            var funcName = functions[i];
            var func = obj[funcName];
            if (!func) {
                continue;
            }
            (function (obj, funcName, func) {
                global[funcName] = function () {
                    return func.apply(obj, arguments);
                };
            })(obj, funcName, func);
        }
    }
    
    *****/
    __asGlobal__() {
        return this.origin.__asGlobal__()
    }
    /*****
    
    function (action, defReturnValue) {
        try {
            return action();
        }
        catch (err) {
            if (err instanceof java.lang.Throwable) {
                exit(err);
            } else {
                if (err instanceof Error) {
                    exit(new org.mozilla.javascript.EvaluatorException(err.name + ": " + err.message, err.fileName, err.lineNumber));
                } else {
                    exit();
                }
            }
            return defReturnValue;
        }
    }
    
    *****/
    __exitIfError__() {
        return this.origin.__exitIfError__()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    setTimeout() {
        return this.origin.setTimeout()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    clearTimeout() {
        return this.origin.clearTimeout()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    setInterval() {
        return this.origin.setInterval()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    clearInterval() {
        return this.origin.clearInterval()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    setImmediate() {
        return this.origin.setImmediate()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    clearImmediate() {
        return this.origin.clearImmediate()
    }
    /*****
    
    function () {
        console.warn("loop() has been deprecated and has no effect. Remove it from your code.");
    }
    
    *****/
    loop() {
        return this.origin.loop()
    }
    /*****
    com.stardust.autojs.runtime.api.Timers@3d907c2
    *****/
    get timers() {
        return this.origin.timers
    }
    /*****
    [object Object]
    *****/
    get $util() {
        return this.origin.$util
    }
    /*****
    [object Object]
    *****/
    get util() {
        return this.origin.util
    }
    /*****
    Device{width=1440, height=3200, buildId='TP1A.220624.014', buildDisplay='TP1A.220624.014', product='rembrandt', board='rembrandt', brand='Redmi', device='rembrandt', model='22122RK93C', bootloader='unknown', hardware='mt6895', fingerprint='Redmi/rembrandt/rembrandt:13/TP1A.220624.014/V14.0.2.0.TMMCNXM:user/release-keys', sdkInt=33, incremental='V14.0.2.0.TMMCNXM', release='13', baseOS='', securityPatch='2023-06-01', serial='unknown'}
    *****/
    get device() {
        return this.origin.device
    }
    /*****
    [object Object]
    *****/
    get process() {
        return this.origin.process
    }
    /*****
    
    function (text) {
        runtime.toast(text);
    }
    
    *****/
    toast(msg: string) {
        return this.origin.toast(msg)
    }
    /*****
    
    function (text) {
        runtime.toast(text);
        this.origin.log(text);
    }
    
    *****/
    toastLog(msg: string) {
        return this.origin.toastLog(msg)
    }
    /*****
    
    function (t) {
        if (ui.isUiThread()) {
            throw new Error("\u4e0d\u80fd\u5728ui\u7ebf\u7a0b\u6267\u884c\u963b\u585e\u64cd\u4f5c\uff0c\u8bf7\u4f7f\u7528setTimeout\u4ee3\u66ff");
        }
        runtime.sleep(t);
    }
    
    *****/
    sleep(n: number) {
        return this.origin.sleep(n)
    }
    /*****
    
    function () {
        return runtime.isStopped();
    }
    
    *****/
    isStopped() {
        return this.origin.isStopped()
    }
    /*****
    undefined
    *****/
    get isShuttingDown() {
        return this.origin.isShuttingDown
    }
    /*****
    
    function () {
        return !isStopped();
    }
    
    *****/
    notStopped() {
        return this.origin.notStopped()
    }
    /*****
    
    function () {
        return !isStopped();
    }
    
    *****/
    isRunning() {
        return this.origin.isRunning()
    }
    /*****
    function () {
        [native code, arity=0]
    }
    
    *****/
    exit() {
        return this.origin.exit()
    }
    /*****
    function () {
        [native code, arity=0]
    }
    
    *****/
    stop() {
        return this.origin.stop()
    }
    /*****
    
    function (text) {
        runtime.setClip(text);
    }
    
    *****/
    setClip(text: string) {
        return this.origin.setClip(text)
    }
    /*****
    
    function (text) {
        return runtime.getClip();
    }
    
    *****/
    getClip() {
        return this.origin.getClip()
    }
    /*****
    
    function () {
        this.origin.auto();
        return runtime.info.getLatestPackage();
    }
    
    *****/
    currentPackage() {
        return this.origin.currentPackage()
    }
    /*****
    
    function () {
        this.origin.auto();
        return runtime.info.getLatestActivity();
    }
    
    *****/
    currentActivity() {
        return this.origin.currentActivity()
    }
    /*****
    
    function (activity, period) {
        ensureNonUiThread();
        period = period || 200;
        while (this.origin.currentActivity() != activity) {
            sleep(period);
        }
    }
    
    *****/
    waitForActivity(activity: string, period: number = 200) {
        return this.origin.waitForActivity(activity, period)
    }
    /*****
    
    function (packageName, period) {
        ensureNonUiThread();
        period = period || 200;
        while (this.origin.currentPackage() != packageName) {
            sleep(period);
        }
    }
    
    *****/
    waitForPackage(packageName: string, period: number = 200) {
        return this.origin.waitForPackage(packageName, period)
    }
    /*****
    
    function (min, max) {
        if (arguments.length == 0) {
            return Math.random();
        }
        return Math.floor(Math.random() * (max - min + 1)) + min;
    }
    
    *****/
    random(min: number, max: number) {
        return this.origin.random(min, max)
    }
    /*****
    function () {
        [native code, arity=0]
    }
    
    *****/
    setScreenMetrics(width: number, height: number) {
        return this.origin.setScreenMetrics(width, height)
    }
    /*****
    function () {
        [native code, arity=0]
    }
    
    *****/
    requiresApi() {
        return this.origin.requiresApi()
    }
    /*****
    
    function (version) {
        if (typeof (version) == "number") {
            if (compare(version, app.autojs.versionCode) > 0) {
                throw new Error("\u9700\u8981Auto.js\u7248\u672c\u53f7" + version + "\u4ee5\u4e0a\u624d\u80fd\u8fd0\u884c");
            }
        } else {
            if (compareVersion(version, app.autojs.versionName) > 0) {
                throw new Error("\u9700\u8981Auto.js\u7248\u672c" + version + "\u4ee5\u4e0a\u624d\u80fd\u8fd0\u884c");
            }
        }
    }
    
    *****/
    requiresAutojsVersion(version: number | string) {
        return this.origin.requiresAutojsVersion(version)
    }
    /*****
    
    function Buffer(arg, encodingOrOffset, length) {
        if (typeof arg === "number") {
            if (typeof encodingOrOffset === "string") {
                throw new TypeError("The \"string\" argument must be of type string. Received type number");
            }
            return allocUnsafe(arg);
        }
        return from(arg, encodingOrOffset, length);
    }
    
    *****/
    Buffer() {
        return this.origin.Buffer
    }
    /*****
    com.stardust.autojs.runtime.api.SevenZip@5d199d3
    *****/
    get zips() {
        return this.origin.zips
    }
    /*****
    com.stardust.autojs.runtime.api.GoogleMLKit@34ef910
    *****/
    get gmlkit() {
        return this.origin.gmlkit
    }
    /*****
    [JavaClass android.content.Intent]
    *****/
    Intent() {
        return this.origin.Intent
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    launchPackage() {
        return this.origin.launchPackage()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    launch() {
        return this.origin.launch()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    launchApp() {
        return this.origin.launchApp()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    getPackageName() {
        return this.origin.getPackageName()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    getAppName() {
        return this.origin.getAppName()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    openAppSetting() {
        return this.origin.openAppSetting()
    }
    /*****
    com.stardust.autojs.runtime.api.AppUtils@3428598
    *****/
    get app() {
        return this.origin.app
    }
    /*****
    com.stardust.autojs.runtime.api.AppUtils@3428598
    *****/
    get $app() {
        return this.origin.$app
    }
    /*****
    
    function (mode) {
        if (mode) {
            this.origin.auto.setMode(mode);
        }
        runtime.accessibilityBridge.ensureServiceEnabled();
    }
    
    *****/
    auto() {
        return this.origin.auto()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    back() {
        return this.origin.back()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    home() {
        return this.origin.home()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    powerDialog() {
        return this.origin.powerDialog()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    notifications() {
        return this.origin.notifications()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    quickSettings() {
        return this.origin.quickSettings()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    recents() {
        return this.origin.recents()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    splitScreen() {
        return this.origin.splitScreen()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    takeScreenshot() {
        return this.origin.takeScreenshot()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    lockScreen() {
        return this.origin.lockScreen()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    dismissNotificationShade() {
        return this.origin.dismissNotificationShade()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    keyCodeHeadsetHook() {
        return this.origin.keyCodeHeadsetHook()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    accessibilityShortcut() {
        return this.origin.accessibilityShortcut()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    accessibilityButtonChooser() {
        return this.origin.accessibilityButtonChooser()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    accessibilityButton() {
        return this.origin.accessibilityButton()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    accessibilityAllApps() {
        return this.origin.accessibilityAllApps()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    dpadUp() {
        return this.origin.dpadUp()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    dpadDown() {
        return this.origin.dpadDown()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    dpadRight() {
        return this.origin.dpadRight()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    dpadLeft() {
        return this.origin.dpadLeft()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    dpadCenter() {
        return this.origin.dpadCenter()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    click(x: number, y: number) {
        return this.origin.click(x, y)
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    longClick(text: string, idx: number = 0): boolean {
        return this.origin.longClick(text, idx)
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    press(x: number, y: number, duration: number) {
        return this.origin.press(x, y, duration)
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    swipe(x1: number, y1: number, x2: number, y2: number, duration: number) {
        return this.origin.swipe(x1, y1, x2, y2, duration)
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    gesture(duration: number, ...points: [number, number][]) {
        return this.origin.gesture(duration, ...points)
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    gestures(...gesture: [number, number?, ...[number, number][]][]) {
        return this.origin.gestures(...gesture)
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    gestureAsync() {
        return this.origin.gestureAsync()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    gesturesAsync() {
        return this.origin.gesturesAsync()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    scrollDown() {
        return this.origin.scrollDown()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    scrollUp() {
        return this.origin.scrollUp()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    input(text: string) {
        return this.origin.input(text)
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    setText(text: string) {
        return this.origin.setText(text)
    }
    /*****
    [object Object]
    *****/
    get automator() {
        return this.origin.automator
    }
    /*****
    [object Object]
    *****/
    get $automator() {
        return this.origin.$automator
    }
    /*****
    function () {
        [native code, arity=0]
    }
    
    *****/
    print() {
        return this.origin.print()
    }
    /*****
    function () {
        [native code, arity=0]
    }
    
    *****/
    log(data: any, ...args: any[]) {
        return this.origin.log(data, ...args)
    }
    /*****
    function () {
        [native code, arity=0]
    }
    
    *****/
    err() {
        return this.origin.err()
    }
    /*****
    function () {
        [native code, arity=0]
    }
    
    *****/
    openConsole() {
        return this.origin.openConsole()
    }
    /*****
    function () {
        [native code, arity=0]
    }
    
    *****/
    clearConsole() {
        return this.origin.clearConsole()
    }
    /*****
    [object Object]
    *****/
    get console() {
        return this.origin.console
    }
    /*****
    [object Object]
    *****/
    get $console() {
        return this.origin.$console
    }
    /*****
    function () {
        [native code, arity=0]
    }
    
    *****/
    rawInput(title: string, prefill?: string) {
        return this.origin.rawInput(title, prefill)
    }
    /*****
    function () {
        [native code, arity=0]
    }
    
    *****/
    alert(title: string, content?: string) {
        return this.origin.alert(title, content)
    }
    /*****
    function () {
        [native code, arity=0]
    }
    
    *****/
    confirm(title: string, content?: string) {
        return this.origin.confirm(title, content)
    }
    /*****
    function () {
        [native code, arity=0]
    }
    
    *****/
    prompt(message?: string, _default?: string) {
        return this.origin.prompt(message, _default)
    }
    /*****
    [object Object]
    *****/
    get dialogs() {
        return this.origin.dialogs
    }
    /*****
    [object Object]
    *****/
    get $dialogs() {
        return this.origin.$dialogs
    }
    /*****
    
    function (path, mode, encoding, bufferSize) {
        if (arguments.length == 1) {
            return files.open(path);
        } else {
            if (arguments.length == 2) {
                return files.open(path, mode);
            } else {
                if (arguments.length == 3) {
                    return files.open(path, mode, encoding);
                } else {
                    if (arguments.length == 4) {
                        return files.open(path, mode, encoding, bufferSize);
                    }
                }
            }
        }
    }
    
    *****/
    open(path: string, mode?: 'w' | 'a' | 'rw', encoding?: string, bufferSize?: number) {
        return this.origin.open(path, mode, encoding, bufferSize)
    }
    /*****
    com.stardust.autojs.runtime.api.Files@ae31c09
    *****/
    get files() {
        return this.origin.files
    }
    /*****
    com.stardust.autojs.runtime.api.Files@ae31c09
    *****/
    get $files() {
        return this.origin.$files
    }
    /*****
    undefined
    *****/
    get io() {
        return this.origin.io
    }
    /*****
    undefined
    *****/
    get $io() {
        return this.origin.$io
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    select() {
        return this.origin.select()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    clickable() {
        return this.origin.clickable()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    focus() {
        return this.origin.focus()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    scrollBackward() {
        return this.origin.scrollBackward()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    password() {
        return this.origin.password()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    descMatches(regex: RegExp | string) {
        return this.origin.descMatches(regex)
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    findOneOf() {
        return this.origin.findOneOf()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    id(resId: string) {
        return this.origin.id(resId)
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    text(str: string) {
        return this.origin.text(str)
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    contextClick() {
        return this.origin.contextClick()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    algorithm(algorithm: 'DFS' | 'BFS') {
        return this.origin.algorithm(algorithm)
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    accessibilityFocus() {
        return this.origin.accessibilityFocus()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    dismiss() {
        return this.origin.dismiss()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    focusable() {
        return this.origin.focusable()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    classNameStartsWith(prefix: string) {
        return this.origin.classNameStartsWith(prefix)
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    scrollTo(options?: ScrollToOptions) {
        return this.origin.scrollTo(options)
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    scrollRight() {
        return this.origin.scrollRight()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    findAndReturnList() {
        return this.origin.findAndReturnList()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    setSelection() {
        return this.origin.setSelection()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    selection() {
        return this.origin.selection()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    bounds(left: number, top: number, right: number, bottom: number) {
        return this.origin.bounds(left, top, right, bottom)
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    addFilter() {
        return this.origin.addFilter()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    columnSpan() {
        return this.origin.columnSpan()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    cut() {
        return this.origin.cut()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    visibleToUser() {
        return this.origin.visibleToUser()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    setProgress() {
        return this.origin.setProgress()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    textMatches(reg: RegExp | string) {
        return this.origin.textMatches(reg)
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    className(str: CommonClassName) {
        return this.origin.className(str)
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    boundsInside() {
        return this.origin.boundsInside()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    enabled() {
        return this.origin.enabled()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    boundsContains() {
        return this.origin.boundsContains()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    findOnce() {
        return this.origin.findOnce()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    descEndsWith() {
        return this.origin.descEndsWith()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    rowCount() {
        return this.origin.rowCount()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    copy() {
        return this.origin.copy()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    textContains() {
        return this.origin.textContains()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    scrollable() {
        return this.origin.scrollable()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    packageNameStartsWith() {
        return this.origin.packageNameStartsWith()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    clearFocus() {
        return this.origin.clearFocus()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    column() {
        return this.origin.column()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    filter() {
        return this.origin.filter()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    depth() {
        return this.origin.depth()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    findOf() {
        return this.origin.findOf()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    exists() {
        return this.origin.exists()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    progress() {
        return this.origin.progress()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    idStartsWith() {
        return this.origin.idStartsWith()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    idEndsWith() {
        return this.origin.idEndsWith()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    descStartsWith() {
        return this.origin.descStartsWith()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    accessibilityFocused() {
        return this.origin.accessibilityFocused()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    untilFindOne() {
        return this.origin.untilFindOne()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    classNameEndsWith() {
        return this.origin.classNameEndsWith()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    indexInParent() {
        return this.origin.indexInParent()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    classNameContains() {
        return this.origin.classNameContains()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    find() {
        return this.origin.find()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    checked() {
        return this.origin.checked()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    scrollLeft() {
        return this.origin.scrollLeft()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    waitFor() {
        return this.origin.waitFor()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    selected() {
        return this.origin.selected()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    clearAccessibilityFocus() {
        return this.origin.clearAccessibilityFocus()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    dismissable() {
        return this.origin.dismissable()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    checkable() {
        return this.origin.checkable()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    drawingOrder() {
        return this.origin.drawingOrder()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    untilFind() {
        return this.origin.untilFind()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    packageNameContains() {
        return this.origin.packageNameContains()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    longClickable() {
        return this.origin.longClickable()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    expand() {
        return this.origin.expand()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    packageNameEndsWith() {
        return this.origin.packageNameEndsWith()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    focused() {
        return this.origin.focused()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    idContains() {
        return this.origin.idContains()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    desc() {
        return this.origin.desc()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    scrollForward() {
        return this.origin.scrollForward()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    textEndsWith() {
        return this.origin.textEndsWith()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    contentInvalid() {
        return this.origin.contentInvalid()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    multiLine() {
        return this.origin.multiLine()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    idMatches() {
        return this.origin.idMatches()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    findOne() {
        return this.origin.findOne()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    show() {
        return this.origin.show()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    descContains() {
        return this.origin.descContains()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    paste() {
        return this.origin.paste()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    contextClickable() {
        return this.origin.contextClickable()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    packageName() {
        return this.origin.packageName()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    row() {
        return this.origin.row()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    rowSpan() {
        return this.origin.rowSpan()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    editable() {
        return this.origin.editable()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    columnCount() {
        return this.origin.columnCount()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    classNameMatches() {
        return this.origin.classNameMatches()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    textStartsWith() {
        return this.origin.textStartsWith()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    packageNameMatches() {
        return this.origin.packageNameMatches()
    }
    /*****
    
    function () {
        var s = selector();
        return s[method].apply(s, Array.prototype.slice.call(arguments));
    }
    
    *****/
    collapse() {
        return this.origin.collapse()
    }
    /*****
    
    function () {
        return __runtime__.selector();
    }
    
    *****/
    selector() {
        return this.origin.selector()
    }
    /*****
    
    function () {
        return __runtime__.selector();
    }
    
    *****/
    $selector() {
        return this.origin.$selector()
    }
    /*****
    
    function (w, h) {
        __runtime__.getRootShell().SetScreenMetrics(w, h);
    }
    
    *****/
    SetScreenMetrics() {
        return this.origin.SetScreenMetrics()
    }
    /*****
    
    function (x, y) {
        __runtime__.getRootShell().Tap(x, y);
    }
    
    *****/
    Tap() {
        return this.origin.Tap()
    }
    /*****
    
    function (x1, y1, x2, y2, duration) {
        if (arguments.length == 5) {
            __runtime__.getRootShell().Swipe(x1, y1, x2, y2, duration);
        } else {
            __runtime__.getRootShell().Swipe(x1, y1, x2, y2);
        }
    }
    
    *****/
    Swipe() {
        return this.origin.Swipe()
    }
    /*****
    
    function (path) {
        __runtime__.getRootShell().Screencap(path);
    }
    
    *****/
    Screencap() {
        return this.origin.Screencap()
    }
    /*****
    
    function (keyCode) {
        __runtime__.getRootShell().KeyCode(keyCode);
    }
    
    *****/
    KeyCode() {
        return this.origin.KeyCode()
    }
    /*****
    
    function () {
        return KeyCode(3);
    }
    
    *****/
    Home() {
        return this.origin.Home()
    }
    /*****
    
    function () {
        return KeyCode(4);
    }
    
    *****/
    Back() {
        return this.origin.Back()
    }
    /*****
    
    function () {
        return KeyCode(26);
    }
    
    *****/
    Power() {
        return this.origin.Power()
    }
    /*****
    
    function () {
        return KeyCode(19);
    }
    
    *****/
    Up() {
        return this.origin.Up()
    }
    /*****
    
    function () {
        return KeyCode(20);
    }
    
    *****/
    Down() {
        return this.origin.Down()
    }
    /*****
    
    function () {
        return KeyCode(21);
    }
    
    *****/
    Left() {
        return this.origin.Left()
    }
    /*****
    
    function () {
        return KeyCode(22);
    }
    
    *****/
    Right() {
        return this.origin.Right()
    }
    /*****
    
    function () {
        return KeyCode(23);
    }
    
    *****/
    OK() {
        return this.origin.OK()
    }
    /*****
    
    function () {
        return KeyCode(24);
    }
    
    *****/
    VolumeUp() {
        return this.origin.VolumeUp()
    }
    /*****
    
    function () {
        return KeyCode(25);
    }
    
    *****/
    VolumeDown() {
        return this.origin.VolumeDown()
    }
    /*****
    
    function () {
        return KeyCode(1);
    }
    
    *****/
    Menu() {
        return this.origin.Menu()
    }
    /*****
    
    function () {
        return KeyCode(27);
    }
    
    *****/
    Camera() {
        return this.origin.Camera()
    }
    /*****
    
    function (text) {
        __runtime__.getRootShell().Text(text);
    }
    
    *****/
    Text() {
        return this.origin.Text()
    }
    /*****
    
    function (text) {
        __runtime__.getRootShell().Text(text);
    }
    
    *****/
    Input() {
        return this.origin.Input()
    }
    /*****
    
    function (cmd, root) {
        root = root ? 1 : 0;
        return __runtime__.shell(cmd, root);
    }
    
    *****/
    shell() {
        return this.origin.shell()
    }
    /*****
    
    function (cmd, root) {
        root = root ? 1 : 0;
        return __runtime__.shell(cmd, root);
    }
    
    *****/
    $shell() {
        return this.origin.$shell()
    }
    /*****
    
    function () {
        return new com.stardust.autojs.core.web.InjectableWebClient(org.mozilla.javascript.Context.getCurrentContext(), scope);
    }
    
    *****/
    newInjectableWebClient() {
        return this.origin.newInjectableWebClient()
    }
    /*****
    
    function (activity) {
        return new com.stardust.autojs.core.web.InjectableWebView(scope.activity, org.mozilla.javascript.Context.getCurrentContext(), scope);
    }
    
    *****/
    newInjectableWebView() {
        return this.origin.newInjectableWebView()
    }
    /*****
    [object Object]
    *****/
    get web() {
        return this.origin.web
    }
    /*****
    [object Object]
    *****/
    get $web() {
        return this.origin.$web
    }
    /*****
    [object UI]
    *****/
    get ui() {
        return this.origin.ui
    }
    /*****
    [object UI]
    *****/
    get $ui() {
        return this.origin.$ui
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    requestScreenCapture() {
        return this.origin.requestScreenCapture()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    captureScreen() {
        return this.origin.captureScreen()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    findImage() {
        return this.origin.findImage()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    findImageInRegion() {
        return this.origin.findImageInRegion()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    findColor() {
        return this.origin.findColor()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    findColorInRegion() {
        return this.origin.findColorInRegion()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    findColorEquals() {
        return this.origin.findColorEquals()
    }
    /*****
    
    function () {
        return func.apply(obj, arguments);
    }
    
    *****/
    findMultiColors() {
        return this.origin.findMultiColors()
    }
    /*****
    com.stardust.autojs.core.image.Colors@d33de0e
    *****/
    get colors() {
        return this.origin.colors
    }
    /*****
    
    function images() {
    }
    
    *****/
    images() {
        return this.origin.images()
    }
    /*****
    
    function images() {
    }
    
    *****/
    $images() {
        return this.origin.$images()
    }
    /*****
    
    function (func, lock) {
        lock = lock || null;
        return new org.mozilla.javascript.Synchronizer(func, lock);
    }
    
    *****/
    sync() {
        return this.origin.sync()
    }
    /*****
    com.stardust.autojs.runtime.api.Threads@992002f
    *****/
    get threads() {
        return this.origin.threads
    }
    /*****
    com.stardust.autojs.runtime.api.Threads@992002f
    *****/
    get $threads() {
        return this.origin.$threads
    }
    /*****
    [JavaClass android.view.KeyEvent]
    *****/
    KeyEvent() {
        return this.origin.KeyEvent
    }
    /*****
    [object Object]
    *****/
    get keys() {
        return this.origin.keys
    }
    /*****
    com.stardust.autojs.runtime.api.Events@292963c
    *****/
    get events() {
        return this.origin.events
    }
    /*****
    com.stardust.autojs.runtime.api.Events@292963c
    *****/
    get $events() {
        return this.origin.$events
    }
    /*****
    [object Object]
    *****/
    get engines() {
        return this.origin.engines
    }
    /*****
    [object Object]
    *****/
    get $engines() {
        return this.origin.$engines
    }
    /*****
    
    function RootAutomator(inputDevice, nonBlockingForReady) {
        inputDevice = inputDevice == undefined ? null : inputDevice;
        this.__ra__ = Object.create(new com.stardust.autojs.core.inputevent.RootAutomator(scope.context, inputDevice, !nonBlockingForReady));
        var methods = ["sendEvent", "touch", "setScreenMetrics", "touchX", "touchY", "sendSync", "sendMtSync", "tap", "swipe", "press", "longPress", "touchDown", "touchUp", "touchMove", "getDefaultId", "setDefaultId", "exit"];
        for (var i = 0; i < methods.length; i++) {
            var method = methods[i];
            this[method] = this.__ra__[method].bind(this.__ra__);
        }
        return this;
    }
    
    *****/
    RootAutomator() {
        return this.origin.RootAutomator
    }
    /*****
    
    function RootAutomator(inputDevice, nonBlockingForReady) {
        inputDevice = inputDevice == undefined ? null : inputDevice;
        this.__ra__ = Object.create(new com.stardust.autojs.core.inputevent.RootAutomator(scope.context, inputDevice, !nonBlockingForReady));
        var methods = ["sendEvent", "touch", "setScreenMetrics", "touchX", "touchY", "sendSync", "sendMtSync", "tap", "swipe", "press", "longPress", "touchDown", "touchUp", "touchMove", "getDefaultId", "setDefaultId", "exit"];
        for (var i = 0; i < methods.length; i++) {
            var method = methods[i];
            this[method] = this.__ra__[method].bind(this.__ra__);
        }
        return this;
    }
    
    *****/
    $RootAutomator() {
        return this.origin.$RootAutomator
    }
    /*****
    [JavaClass com.stardust.autojs.core.http.MutableOkHttp]
    *****/
    MutableOkHttp() {
        return this.origin.MutableOkHttp
    }
    /*****
    [object Object]
    *****/
    get http() {
        return this.origin.http
    }
    /*****
    [object Object]
    *****/
    get $http() {
        return this.origin.$http
    }
    /*****
    [object Object]
    *****/
    get storages() {
        return this.origin.storages
    }
    /*****
    [object Object]
    *****/
    get $storages() {
        return this.origin.$storages
    }
    /*****
    [object Object]
    *****/
    get floaty() {
        return this.origin.floaty
    }
    /*****
    [object Object]
    *****/
    get $floaty() {
        return this.origin.$floaty
    }
    /*****
    com.stardust.autojs.runtime.api.Sensors@986fc5
    *****/
    get sensors() {
        return this.origin.sensors
    }
    /*****
    com.stardust.autojs.runtime.api.Sensors@986fc5
    *****/
    get $sensors() {
        return this.origin.$sensors
    }
    /*****
    com.stardust.autojs.runtime.api.Media@a53cd1a
    *****/
    get media() {
        return this.origin.media
    }
    /*****
    com.stardust.autojs.runtime.api.Media@a53cd1a
    *****/
    get $media() {
        return this.origin.$media
    }
    /*****
    
    function plugins() {
    }
    
    *****/
    plugins() {
        return this.origin.plugins()
    }
    /*****
    
    function plugins() {
    }
    
    *****/
    $plugins() {
        return this.origin.$plugins()
    }
    /*****
    
    function continuation() {
    }
    
    *****/
    continuation() {
        return this.origin.continuation()
    }
    /*****
    
    function continuation() {
    }
    
    *****/
    $continuation() {
        return this.origin.$continuation()
    }
    /*****
    
    function $zip() {
    }
    
    *****/
    $zip() {
        return this.origin.$zip()
    }
    /*****
    
    function $base64() {
    }
    
    *****/
    $base64() {
        return this.origin.$base64()
    }
    /*****
    
    function $cypto() {
    }
    
    *****/
    $crypto() {
        return this.origin.$crypto()
    }
    /*****
    [object Object]
    *****/
    get paddle() {
        return this.origin.paddle
    }
    /*****
    [object Object]
    *****/
    get $paddle() {
        return this.origin.$paddle
    }
    /*****
    [JavaClass com.stardust.autojs.core.util.Shell]
    *****/
    Shell() {
        return this.origin.Shell
    }
    /*****
    [JavaClass android.graphics.Paint]
    *****/
    Paint() {
        return this.origin.Paint
    }
    /*****
    [JavaClass com.stardust.autojs.core.graphics.ScriptCanvas]
    *****/
    Canvas() {
        return this.origin.Canvas
    }
    /*****
    [JavaClass com.stardust.autojs.core.image.ImageWrapper]
    *****/
    Image() {
        return this.origin.Image
    }
    /*****
    [JavaClass okhttp3.OkHttpClient]
    *****/
    OkHttpClient() {
        return this.origin.OkHttpClient
    }
    /*****
    
    function Module(id, parent, core) {
        this.id = id;
        this.core = core;
        this.parent = parent;
        this.children = [];
        this.filename = id;
        this.loaded = false;
        Object.defineProperty(this, "exports", {get: function () {
            return this._exports;
        }.bind(this), set: function (val) {
            Require.cache[this.filename] = val;
            this._exports = val;
        }.bind(this)});
        this.exports = {};
        if (parent && parent.children) {
            parent.children.push(this);
        }
        this.require = function (id) {
            return Require(id, this);
        }.bind(this);
    }
    
    *****/
    Module() {
        return this.origin.Module
    }
    /*****
    [object Object]
    *****/
    get Reflect() {
        return this.origin.Reflect
    }
    /*****
    [JavaClass android.app.ActivityManager]
    *****/
    ActivityManager() {
        return this.origin.ActivityManager
    }
    /*****
    [JavaClass android.app.ActivityManagerNative]
    *****/
    ActivityManagerNative() {
        return this.origin.ActivityManagerNative
    }
    /*****
    [JavaClass android.app.Activity]
    *****/
    Activity() {
        return this.origin.Activity
    }
    /*****
    [JavaClass android.app.Service]
    *****/
    Service() {
        return this.origin.Service
    }
    /*****
    [JavaClass android.app.usage.UsageStats]
    *****/
    UsageStats() {
        return this.origin.UsageStats
    }
    /*****
    [JavaClass android.app.usage.UsageStatsManager]
    *****/
    UsageStatsManager() {
        return this.origin.UsageStatsManager
    }
    /*****
    [JavaClass android.content.Context]
    *****/
    Context() {
        return this.origin.Context
    }
    /*****
    [JavaClass android.os.IBinder]
    *****/
    IBinder() {
        return this.origin.IBinder
    }
    /*****
    [JavaClass android.os.Bundle]
    *****/
    Bundle() {
        return this.origin.Bundle
    }
    /*****
    [JavaClass android.os.Build]
    *****/
    Build() {
        return this.origin.Build
    }
    /*****
    [JavaClass android.util.Log]
    *****/
    Log() {
        return this.origin.Log
    }
    /*****
    [JavaClass android.view.View]
    *****/
    View() {
        return this.origin.View
    }
    /*****
    [JavaClass android.widget.Button]
    *****/
    Button() {
        return this.origin.Button
    }
    /*****
    [JavaClass android.widget.DatePicker]
    *****/
    DatePicker() {
        return this.origin.DatePicker
    }
    /*****
    [JavaClass android.widget.TimePicker]
    *****/
    TimePicker() {
        return this.origin.TimePicker
    }
    /*****
    [JavaClass android.widget.Toast]
    *****/
    Toast() {
        return this.origin.Toast
    }
    /*****
    [JavaClass java.io.IOException]
    *****/
    IOException() {
        return this.origin.IOException
    }
    /*****
    [JavaClass java.net.DatagramPacket]
    *****/
    DatagramPacket() {
        return this.origin.DatagramPacket
    }
    /*****
    [JavaClass java.net.DatagramSocket]
    *****/
    DatagramSocket() {
        return this.origin.DatagramSocket
    }
    /*****
    [JavaClass java.net.InetAddress]
    *****/
    InetAddress() {
        return this.origin.InetAddress
    }
    /*****
    [JavaClass java.net.SocketException]
    *****/
    SocketException() {
        return this.origin.SocketException
    }
    /*****
    [JavaClass java.text.SimpleDateFormat]
    *****/
    SimpleDateFormat() {
        return this.origin.SimpleDateFormat
    }
    /*****
    [JavaClass java.util.Calendar]
    *****/
    Calendar() {
        return this.origin.Calendar
    }
}